<?php

namespace app\api\controller;

use app\common\controller\Api;
use think\Db;
/**
 * 主题
 */
class Adv extends Api{
    // 无需登录的接口,*表示全部
    protected $noNeedLogin = ['*'];
    // 无需鉴权的接口,*表示全部
    protected $noNeedRight = ['*'];

    public function video(){
        $banner = Db::name('AdvVideo')->where('status',1)->find();
        if(!empty($banner)){

            $banner['video'] = cdnurl($banner['video']);
        }else{
            $banner = [];
        }
        $this->success('视频广告',$banner);
    }
}